package com.zhongkai.web.control.config;

import java.io.IOException;

import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;

import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;

import com.zhongkai.model.config.User;

@Controller
public class LoginOutControl {

	/*退出*/
	@RequestMapping(value="/logout.do")
	public String loginOut(HttpServletRequest request,HttpServletResponse response) throws IOException{
		request.getSession().removeAttribute("user");
		request.getSession().removeAttribute("menuAction");
		request.getSession().removeAttribute("buttonAction");
		request.getSession().removeAttribute("actionUrl");
		return "redirect:/login.jsp";
	}
}
